/*
* Created by zhangkun on 2017/12/07
*/
define([
  './themes/lang/' + window.YUFP_SYS_CONFIG.language + '/pages/example/template/formnesttab.js'
], function (require, exports) {
  exports.ready = function (hashCode, data, cite) {
    yufp.lookup.reg('NATIONALITY,PUBLISH_STATUS,GENDER,EDUCATION_TYPE,IDENT_TYPE');
    var vm = yufp.custom.vue({
      el: '#template_formnesttab',
      data: function () {
        return {
          tabName: 'first',
          baseFields: [{
            columnCount: 2,
            fields: [
              { field: 'name', label: this.$t('formnesttab.xm') },
              { field: 'gender', label: this.$t('formnesttab.xb'), type: 'select', dataCode: 'GENDER' },
              { field: 'education', label: this.$t('formnesttab.xl'), type: 'select', dataCode: 'EDUCATION_TYPE' },
              { field: 'cardType', label: this.$t('formnesttab.zjlx'), type: 'select', dataCode: 'IDENT_TYPE' },
              { field: 'barthday', label: this.$t('formnesttab.csrq'), type: 'date' },
              { field: 'cardNo', label: this.$t('formnesttab.zjhm') },
              { field: 'company', label: this.$t('formnesttab.gs') },
              { field: 'email', label: this.$t('formnesttab.yx') }
            ]
          }],

          tableColumns: [
            { label: this.$t('formnesttab.bm'), prop: 'id', width: 110 },
            { label: this.$t('formnesttab.mc'), prop: 'title', width: 200, sortable: true, resizable: true },
            { label: this.$t('formnesttab.lx'), prop: 'type', width: 110, dataCode: 'NATIONALITY' },
            { label: this.$t('formnesttab.zz'), prop: 'author', width: 110 },
            { label: this.$t('formnesttab.shr'), prop: 'auditor', width: 110 },
            { label: this.$t('formnesttab.yds'), prop: 'pageviews', width: 100 },
            { label: this.$t('formnesttab.zt'), prop: 'status', width: 120, dataCode: 'PUBLISH_STATUS' },
            { label: this.$t('formnesttab.sj'), prop: 'create_at'}
          ]
        };
      }
    });
  };
});
